﻿using Microsoft.AspNetCore.Mvc;
using Microsoft.Extensions.Options;

namespace SmartFactory.Controllers
{
    
    public class OutboundOrderController : Controller
    {


        private readonly IpAddressesConfig _ipAddressesConfig;

        public OutboundOrderController(IOptions<IpAddressesConfig> ipAddressesConfig)
        {
            _ipAddressesConfig = ipAddressesConfig.Value;
        }


        /// <summary>
        /// 出库单显示视图
        /// </summary>
        /// <returns>返回出库单显示试图</returns>
        public IActionResult OutboundOrderShowView()
        {
            ViewBag.Darius = _ipAddressesConfig.Darius;
            ViewBag.Durian = _ipAddressesConfig.Durian;
            ViewBag.GlennQuigmrire = _ipAddressesConfig.GlennQuigmrire;
            ViewBag.Keep = _ipAddressesConfig.Keep;
            ViewBag.GoldIngot = _ipAddressesConfig.GoldIngot;
            return View();
        }

        /// <summary>
        /// 出库单添加页面
        /// </summary>
        /// <returns>返回出库单添加试图</returns>
        public IActionResult OutboundAddView()
        {
            ViewBag.Darius = _ipAddressesConfig.Darius;
            ViewBag.Durian = _ipAddressesConfig.Durian;
            ViewBag.GlennQuigmrire = _ipAddressesConfig.GlennQuigmrire;
            ViewBag.Keep = _ipAddressesConfig.Keep;
            ViewBag.GoldIngot = _ipAddressesConfig.GoldIngot;
            return View();
        }


    }
}
